feat: added async & persistent options to Cache Redis#9792
feat: added async & persistent options to Cache Redis#9792michalsn merged 11 commits intocodeigniter4:4.7from
async & persistent options to Cache Redis#9792Conversation
|
No tests required? Change config in https://github.com/codeigniter4/CodeIgniter4/blob/4.7/user_guide_src/source/libraries/caching.rst#redis-caching |
michalsn
left a comment
There was a problem hiding this comment.
PHPRedis can also support the persistent option, so we should add it there too via pconnect().
The async option should note that it is used only with Predis.
Preferably, all these new options should be mentioned here: https://codeigniter.com/user_guide/libraries/caching.html#redis-caching
We could introduce a separate configuration parameter for Predis in the config and switch to using new Redis() in the PHPRedis implementation. This would allow us to support all available options in both clients without worrying about missing or incompatible parameters. However, this change would introduce a minor BC break. Thoughts?
async & persistent options to cache predisasync & persistent options to Cache Redis
|
Added for redis handler too. I want make support Sentinel, but for next PR. Maybe separate config in that PR |
neznaika0
left a comment
There was a problem hiding this comment.
I don't use Redis, but it looks good.
|
PR #9793 for |
michalsn
left a comment
There was a problem hiding this comment.
Looks good, thanks!
PHPStan errors are not related.
|
@ddevsr The |
Co-authored-by: Michal Sniatala <[email protected]>
Co-authored-by: Michal Sniatala <[email protected]>
Co-authored-by: Michal Sniatala <[email protected]>
Co-authored-by: John Paul E. Balandan, CPA <[email protected]>
7e3f107 to
7385984
Compare
|
Thank you @ddevsr! |
Description
Added config item to Redis in
Cache.Parameter:
asyncandpersistentconfig item to predis handler.persistentconfig item to redis handler.Checklist: